home *** CD-ROM | disk | FTP | other *** search
- KIDD0002.MOD
- Kidd #20 @8315
- 3Wednesday, July 15, 1992 1 4:09 pm
- 7[1Msg Status7]2: 1Reply Requested.
-
-
- MOD Name - KIDD0002
- Author - Kidd
- Date - 7/13/92
- Version - WWIV v4.21 <may work with older/newer versions>
-
- Explanation - I found a nice little MOD that asked by The Flying Chicken
- that put in a log on lottery to use with the Gold System MODs.
- I really hate the Gold System so I made a few modifications
- to his MOD. All credit goes to The Flying Chicken. I just
- used what was already there.
-
- Disclaimer - I'm not responsible. Use it as your own risk!
-
- /***************************************************************************\
-
- Legend -
-
- == existing code
- ++ add code
- -- delete code
-
- /***************************************************************************\
-
- Step One - Backup source code. If you really need to. Your choice.
-
- Step Two - Load up LILO.C and search for -> void logon() <-
- Add this procedure right before it. Follow directions on the
- left margin!
-
- ++ void slot_machine()
- ++ {
- ++ int i,p1,p2,p3,matches,time;
- ++ char s[81];
- ++
- ++ nl();
- ++ sprintf(s,"2Welcome to 1%s's 3M2ega 3T2ime 3S2lot 3M2achine6!",syscfg.systemname);
- ++ prt(2,s);
- ++ nl();
- ++ nl();
- ++ prt(2,"You will see three numbers changing rapidly below. When you are");
- ++ nl();
- ++ prt(2,"ready, press a key to lock in the first number. Then lock in the");
- ++ nl();
- ++ prt(2,"last two numbers the same way. If two of the numbers match, you");
- ++ nl();
- ++ prt(2,"will receive 552 more minutes. If all three match, you will win");
- ++ nl();
- ++ prt(2,"5102 more minutes. Good luck6!");
- ++ nl();
- ++ nl();
- ++ npr("* * *\b\b\b\b\b");
- ++ i=0;
- ++ do {
- ++ npr("%d\b",i);
- ++ i++;
- ++ if (i>9)
- ++ i=0;
- ++ } while (inkey()==0);
- ++ p1=i;
- ++ npr("%d ",p1);
- ++ i=5;
- ++ do {
- ++ npr("%d\b",i);
- ++ i++;
- ++ if (i>9)
- ++ i=0;
- ++ } while (inkey()==0);
- ++ p2=i;
- ++ npr("%d ",p2);
- ++ i=9;
- ++ do {
- ++ npr("%d\b",i);
- ++ i++;
- ++ if (i>9)
- ++ i=0;
- ++ } while (inkey()==0);
- ++ p3=i;
- ++ npr("%d \r\n",p3);
- ++
- ++ matches=0;
- ++ if (p1==p2)
- ++ matches++;
- ++ if (p1==p3)
- ++ matches++;
- ++ if (p2==p3)
- ++ matches++;
- ++
- ++ ansic(1);
- ++ if (matches==1) {
- ++ nl();
- ++ npr("6Two 2numbers matched6!\r\n");
- ++ time=5;
- ++ thisuser.extratime+=5.0*60.0;
- ++ tleft(0);
- ++ }
- ++ if (matches==3) {
- ++ nl();
- ++ npr("2My GOD you matched 6three 2numbers6!!\r\n");
- ++ time=10;
- ++ thisuser.extratime+=10.0*60.0;
- ++ tleft(0);
- ++ }
- ++ if (matches==0) {
- ++ nl();
- ++ npr("2No numbers matched\r\n");
- ++ }
- ++
- ++ nl();
- ++ if (matches>0) {
- ++ npr("2Congratulations6!!2 You have just won 7%d 2more minutes6!!\r\n",time);
- ++ sprintf(s,"!!! %s won %d more minutes at the slot machine !!!",nam(&thisuser,usernum),time);
- ++ sysoplog(s);
- ++ } else
- ++ npr("2Aww...5Better luck next time\r\n");
- ++
- ++ nl();
- ++ prt(2,"Thanxs for playing ");
- ++ prt(1,syscfg.systemname);
- ++ prt(1,"'s 3M2ega 3T2ime 3S2lot 3M2achine6!");
- ++ nl();
- ++ nl();
- ++ }
-
- /*This part is set up to give users 5 minutes if 2 matches and 10 if three
- matches. You can alter this by changing the xx.x in this line
- ─> 'thisuser.extratime+=xx.x*60.0' <─ and then changing ─> time=xx <─.*/
-
- Step Three - Now search for ─> 'void logon()' <─. Find this line
- ─> status.net_version); <─. Right after it add this.
-
- ++ if (thisuser.ontoday<4) {
- ++ nl();
- ++ prt(2,"Would you like to try the Lottery? ");
- ++ if (yn())
- ++ slot_machine();
- ++ }
-
- /*This part is set up to let the user play only three times a day. To
- alter change the x in ─> if (thisuser.ontoday<x) { <─ to the number
- of times you want them to play*/
-
- Step Four - Save LILO.C and compile!
-
- /***************************************************************************\
-
- This is a product from the Trixter BBS brought to you by the Kidd! If you
- find anything wrong, or anything that could be written better just post on
- the net!
-
-
- 7===============================================================================0
- 7░░▒▒▓▓ 1T2he 1T2rading 1P2ost 7[1SOUTH7] 5WWIVNet 1@8315 3803-731-0690 7▓▓▒▒░░0
- 4ßeta test and distribution site for WOMR, ECLIPSE, WWIVEDIT, AND S. REALMS!0
-